<!-- HTML header for doxygen 1.8.14-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="cache-control" content="max-age=86400"/>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>GBDK 2020 Docs: gbdk-lib/include/stdio.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="doxygen_extra.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">GBDK 2020 Docs
   &#160;<span id="projectnumber">4.4.0</span>
   </div>
   <div id="projectbrief">API Documentation for GBDK 2020</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('stdio_8h.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">stdio.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><code>#include &lt;<a class="el" href="types_8h_source.html">types.h</a>&gt;</code><br />
</div>
<p><a href="stdio_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:aab41487f7727cf7eb7377f9b8f494c58"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="stdio_8h.html#aab41487f7727cf7eb7377f9b8f494c58">putchar</a> (char <a class="el" href="sms_8h.html#a0b3366755f3276b0243c1e0497471b7a">c</a>) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a> REENTRANT</td></tr>
<tr class="separator:aab41487f7727cf7eb7377f9b8f494c58"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a133c04c35a1c14c6f8d8078831705661"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="stdio_8h.html#a133c04c35a1c14c6f8d8078831705661">printf</a> (const char *format,...)</td></tr>
<tr class="separator:a133c04c35a1c14c6f8d8078831705661"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a440c82287022737c4f2866786ba8a154"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="stdio_8h.html#a440c82287022737c4f2866786ba8a154">sprintf</a> (char *str, const char *format,...)</td></tr>
<tr class="separator:a440c82287022737c4f2866786ba8a154"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a299d0f9cb9e7b14e1278a4ed21e4d76f"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="stdio_8h.html#a299d0f9cb9e7b14e1278a4ed21e4d76f">puts</a> (const char *s)</td></tr>
<tr class="separator:a299d0f9cb9e7b14e1278a4ed21e4d76f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a00a5b27bc2e5280952b02c304d7b27bc"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="stdio_8h.html#a00a5b27bc2e5280952b02c304d7b27bc">gets</a> (char *s) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr>
<tr class="separator:a00a5b27bc2e5280952b02c304d7b27bc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a59f236a67cfbffee7aff0c369bcf3f2b"><td class="memItemLeft" align="right" valign="top">char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="stdio_8h.html#a59f236a67cfbffee7aff0c369bcf3f2b">getchar</a> (void) <a class="el" href="asm_2types_8h.html#a0971918860055db2e50dacea4da8f3bc">OLDCALL</a></td></tr>
<tr class="separator:a59f236a67cfbffee7aff0c369bcf3f2b"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Basic file/console input output functions.</p>
<p>Including stdio.h will use a large number of the background tiles for font characters. If stdio.h is not included then that space will be available for use with other tiles instead. </p>
</div><h2 class="groupheader">Function Documentation</h2>
<a id="aab41487f7727cf7eb7377f9b8f494c58"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aab41487f7727cf7eb7377f9b8f494c58">&#9670;&nbsp;</a></span>putchar()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void putchar </td>
          <td>(</td>
          <td class="paramtype">char&#160;</td>
          <td class="paramname"><em>c</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Print char to stdout. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">c</td><td>Character to print </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a133c04c35a1c14c6f8d8078831705661"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a133c04c35a1c14c6f8d8078831705661">&#9670;&nbsp;</a></span>printf()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void printf </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>format</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname"><em>...</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Print the string and arguments given by format to stdout.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">format</td><td>The format string as per printf</td></tr>
  </table>
  </dd>
</dl>
<p>Does not return the number of characters printed.</p>
<p>Currently supported: </p><ul>
<li>%hx (char as hex) </li>
<li>%hu (unsigned char) </li>
<li>%hd (signed char) </li>
<li>%c (character) </li>
<li>%u (unsigned int) </li>
<li>%d (signed int) </li>
<li>%x (unsigned int as hex) </li>
<li>%s (string)</li>
</ul>
<p>Warning: to correctly pass parameters (such as chars, ints, etc) <b>all of them should always be explicitly cast</b> as when calling the function. See <a class="el" href="docs_coding_guidelines.html#docs_chars_varargs">docs_chars_varargs</a> for more details. </p>

</div>
</div>
<a id="a440c82287022737c4f2866786ba8a154"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a440c82287022737c4f2866786ba8a154">&#9670;&nbsp;</a></span>sprintf()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void sprintf </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>str</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>format</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname"><em>...</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Print the string and arguments given by format to a buffer.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">str</td><td>The buffer to print into </td></tr>
    <tr><td class="paramname">format</td><td>The format string as per <a class="el" href="stdio_8h.html#a133c04c35a1c14c6f8d8078831705661">printf</a></td></tr>
  </table>
  </dd>
</dl>
<p>Does not return the number of characters printed.</p>
<p>Warning: to correctly pass parameters (such as chars, ints, etc) <b>all of them should always be explicitly cast</b> as when calling the function. See <a class="el" href="docs_coding_guidelines.html#docs_chars_varargs">docs_chars_varargs</a> for more details. </p>

</div>
</div>
<a id="a299d0f9cb9e7b14e1278a4ed21e4d76f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a299d0f9cb9e7b14e1278a4ed21e4d76f">&#9670;&nbsp;</a></span>puts()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void puts </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>s</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p><a class="el" href="stdio_8h.html#a299d0f9cb9e7b14e1278a4ed21e4d76f">puts()</a> writes the string <b>s</b> and a trailing newline to stdout. </p>

</div>
</div>
<a id="a00a5b27bc2e5280952b02c304d7b27bc"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a00a5b27bc2e5280952b02c304d7b27bc">&#9670;&nbsp;</a></span>gets()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char* gets </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>s</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p><a class="el" href="stdio_8h.html#a00a5b27bc2e5280952b02c304d7b27bc">gets()</a> Reads a line from stdin into a buffer pointed to by <b>s</b>.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">s</td><td>Buffer to store string in</td></tr>
  </table>
  </dd>
</dl>
<p>Reads until either a terminating newline or an EOF, which it replaces with '\0'. No check for buffer overrun is performed.</p>
<p>Returns: Buffer pointed to by <b>s</b> </p>

</div>
</div>
<a id="a59f236a67cfbffee7aff0c369bcf3f2b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a59f236a67cfbffee7aff0c369bcf3f2b">&#9670;&nbsp;</a></span>getchar()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char getchar </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p><a class="el" href="stdio_8h.html#a59f236a67cfbffee7aff0c369bcf3f2b">getchar()</a> Reads and returns a single character from stdin. </p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.14-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
</div>
</body>
</html>
